// Copyright 2007-2009 The SharpSvn Project
//
//  Licensed under the Apache License, Version 2.0 (the "License");
//  you may not use this file except in compliance with the License.
//  You may obtain a copy of the License at
//
//    http://www.apache.org/licenses/LICENSE-2.0
//
//  Unless required by applicable law or agreed to in writing, software
//  distributed under the License is distributed on an "AS IS" BASIS,
//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//  See the License for the specific language governing permissions and
//  limitations under the License.

#include "stdafx.h"
#include "SvnLibraryAttribute.h"

#include <stdint.h>

#pragma warning(disable: 4635)
#pragma warning(disable: 4634) // XML document comment: cannot be applied:  Discarding XML document comment for invalid target.

#include <apr-1/apr_version.h>
#include <apr-1/apu_version.h>
#if (APU_HAVE_APR_ICONV != 0)
#include <apr-1/api_version.h>
#endif
#include <svn_version.h>
#include <openssl/opensslv.h>
#include <db.h>
#include <expat.h>
#include "../SharpPlink/SharpPlinkVersion.h"
#define STRUCT_IOVEC_DEFINED // Kill compile error

#include <sasl/sasl.h>	// Generated by our import script as we can't use config.h
#include <sqlite3.h>
#define Byte ZByte
#include <zlib.h>
#undef Byte

extern "C" {
#include <svn-internal/libsvn_subr/utf8proc/utf8proc_internal.h>
#define SVN_INTERNAL_LZ4 1
#include <svn-internal/libsvn_subr/lz4/lz4internal.h>
};

using namespace System;
using namespace System::Reflection;
using namespace System::Resources;
using namespace System::Runtime::CompilerServices;
using namespace System::Runtime::InteropServices;
using namespace System::Security::Permissions;
using SharpSvn::Implementation::SvnLibraryAttribute;

#define SERF_VERSION APR_STRINGIFY(SERF_MAJOR_VERSION) \
    "." APR_STRINGIFY(SERF_MINOR_VERSION) \
    "." APR_STRINGIFY(SERF_PATCH_VERSION)

#define BDB_VERSION APR_STRINGIFY(DB_VERSION_MAJOR) "." APR_STRINGIFY(DB_VERSION_MINOR) "." APR_STRINGIFY(DB_VERSION_PATCH)
#define EXPAT_VERSION APR_STRINGIFY(XML_MAJOR_VERSION) "." APR_STRINGIFY(XML_MINOR_VERSION) "." APR_STRINGIFY(XML_MICRO_VERSION)
#define LZ4_VERSION APR_STRINGIFY(LZ4_VERSION_MAJOR) "." APR_STRINGIFY(LZ4_VERSION_MINOR) "." APR_STRINGIFY(LZ4_VERSION_RELEASE)
#define SASL_VERSION APR_STRINGIFY(SASL_VERSION_MAJOR) "." APR_STRINGIFY(SASL_VERSION_MINOR) "." APR_STRINGIFY(SASL_VERSION_STEP)
#define UTF8PROC_VERSION APR_STRINGIFY(UTF8PROC_VERSION_MAJOR) "." APR_STRINGIFY(UTF8PROC_VERSION_MINOR) "." APR_STRINGIFY(UTF8PROC_VERSION_PATCH)

//
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
//
[assembly:AssemblyTitleAttribute("SharpSvn - Subversion for .Net 4+ and .Net Core 3+")];
[assembly:AssemblyDescriptionAttribute("SharpSvn, compiled statically with subversion " SVN_VER_NUMBER
    ", apr " APR_VERSION_STRING
    ", apr-util " APU_VERSION_STRING
    ", Cyrus Sasl " SASL_VERSION
    ", eXpat " EXPAT_VERSION
    ", LibSSH2 " LIBSSH2_VERSION
    ", LZ4 " LZ4_VERSION
    ", " OPENSSL_VERSION_TEXT
    ", serf " SERF_VERSION
    ", sqlite " SQLITE_VERSION
    ", utf8proc " UTF8PROC_VERSION
    ", zlib " ZLIB_VERSION
    " and " OPENSSL_VERSION_TEXT
    ". If available this library also uses the optional Berkeley DB " BDB_VERSION
    " and our compilation of Putty's Plink " PLINK_VER_NUMBER)];
[assembly:AssemblyConfigurationAttribute("")];
[assembly:AssemblyCompanyAttribute("SharpSvn Project")];
[assembly:AssemblyProductAttribute("SharpSvn")];
[assembly:AssemblyCopyrightAttribute("Copyright (c) SharpSvn Project 2006-2021")];
[assembly:AssemblyTrademarkAttribute("")];
[assembly:AssemblyCultureAttribute("")];

[assembly:SvnLibrary("Subversion", SVN_VER_NUMBER)];
[assembly:SvnLibrary("Apr", APR_VERSION_STRING)];
[assembly:SvnLibrary("Apr-util", APU_VERSION_STRING)];
[assembly:SvnLibrary("Cyrus Sasl", SASL_VERSION)];
[assembly:SvnLibrary("eXpat", EXPAT_VERSION)];
[assembly:SvnLibrary("LibSSH2", LIBSSH2_VERSION)]
[assembly:SvnLibrary("LZ4", LZ4_VERSION)]
[assembly:SvnLibrary("Serf", SERF_VERSION)];
[assembly:SvnLibrary("SQLite", SQLITE_VERSION)];
[assembly:SvnLibrary("Utf8proc", UTF8PROC_VERSION)];
[assembly:SvnLibrary("ZLib", ZLIB_VERSION)];
[assembly:SvnLibrary("OpenSSL", OPENSSL_VERSION_TEXT, SkipPrefix = true)];
[assembly:SvnLibrary("Berkeley DB", BDB_VERSION, DynamicallyLinked = true, Optional = true)];
[assembly:SvnLibrary("SharpPlink", PLINK_VER_NUMBER, DynamicallyLinked = true, Optional = true)];

//
// Version information for an assembly consists of the following four values:
//
//      Major Version
//      Minor Version
//      Build Number
//      Revision
//
// You can specify all the value or you can default the Revision and Build Numbers
// by using the '*' as shown below:

[assembly:NeutralResourcesLanguageAttribute("en-US")];

[assembly:ComVisible(false)];

[assembly:CLSCompliantAttribute(true)];

#if __CLR_VER < 40000000 && !defined(SHARPSVN_NETCORE)
[assembly:SecurityPermission(SecurityAction::RequestMinimum, UnmanagedCode = true)];
#endif

[assembly:RuntimeCompatibility(WrapNonExceptionThrows = true)];

#include "../../imports/release/include/sharpsvn-imports.h"
[assembly:AssemblyVersionAttribute("1.12999.*")];
